﻿using System;
using System.Data;
using System.Data.Common;
using Hxj.Data;
using Hxj.Data.Common;

namespace RecruitStudents.Utility.Model
{

	/// <summary>
	/// 实体类TB_Sys_SpecialityLevelMapping 。(属性说明自动提取数据库字段的描述信息)
	/// </summary>
	[Serializable]
	public class TB_Sys_SpecialityLevelMapping : Entity 
	{
		public TB_Sys_SpecialityLevelMapping():base("TB_Sys_SpecialityLevelMapping") {    _SpecialityLevelID=Guid.NewGuid().ToString();}


        #region Model
        private string _SpecialityLevelID;
        private string _SpecialityKindsNO;
        private string _ExamLevelNO;
        private string _ExamLevelName;
        /// <summary>
        /// 主键
        /// </summary>
        public string SpecialityLevelID
        {
            get { return _SpecialityLevelID; }
            set
            {
                this.OnPropertyValueChange(_.SpecialityLevelID, _SpecialityLevelID, value);
                this._SpecialityLevelID = value;
            }
        }
        /// <summary>
        /// 专业编码
        /// </summary>
        public string SpecialityKindsNO
        {
            get { return _SpecialityKindsNO; }
            set
            {
                this.OnPropertyValueChange(_.SpecialityKindsNO, _SpecialityKindsNO, value);
                this._SpecialityKindsNO = value;
            }
        }
        /// <summary>
        /// 考试级别
        /// </summary>
        public string ExamLevelNO
        {
            get { return _ExamLevelNO; }
            set
            {
                this.OnPropertyValueChange(_.ExamLevelNO, _ExamLevelNO, value);
                this._ExamLevelNO = value;
            }
        }
        /// <summary>
        /// 考试级别名称
        /// </summary>
        public string ExamLevelName
        {
            get { return _ExamLevelName; }
            set
            {
                this.OnPropertyValueChange(_.ExamLevelName, _ExamLevelName, value);
                this._ExamLevelName = value;
            }
        }
        #endregion

        #region Method
        /// <summary>
        /// 获取实体中的主键列
        /// </summary>
        public override Field[] GetPrimaryKeyFields()
        {
            return new Field[] {
				_.SpecialityLevelID};
        }
        /// <summary>
        /// 获取列信息
        /// </summary>
        public override Field[] GetFields()
        {
            return new Field[] {
				_.SpecialityLevelID,
				_.SpecialityKindsNO,
				_.ExamLevelNO,
				_.ExamLevelName};
        }
        /// <summary>
        /// 获取值信息
        /// </summary>
        public override object[] GetValues()
        {
            return new object[] {
				this._SpecialityLevelID,
				this._SpecialityKindsNO,
				this._ExamLevelNO,
				this._ExamLevelName};
        }
        /// <summary>
        /// 给当前实体赋值
        /// </summary>
        public override void SetPropertyValues(IDataReader reader)
        {
            this._SpecialityLevelID = DataUtils.ConvertValue<string>(reader["SpecialityLevelID"]);
            this._SpecialityKindsNO = DataUtils.ConvertValue<string>(reader["SpecialityKindsNO"]);
            this._ExamLevelNO = DataUtils.ConvertValue<string>(reader["ExamLevelNO"]);
            this._ExamLevelName = DataUtils.ConvertValue<string>(reader["ExamLevelName"]);
        }
        /// <summary>
        /// 给当前实体赋值
        /// </summary>
        public override void SetPropertyValues(DataRow row)
        {
            this._SpecialityLevelID = DataUtils.ConvertValue<string>(row["SpecialityLevelID"]);
            this._SpecialityKindsNO = DataUtils.ConvertValue<string>(row["SpecialityKindsNO"]);
            this._ExamLevelNO = DataUtils.ConvertValue<string>(row["ExamLevelNO"]);
            this._ExamLevelName = DataUtils.ConvertValue<string>(row["ExamLevelName"]);
        }
        #endregion

        #region _Field
        /// <summary>
        /// 字段信息
        /// </summary>
        public class _
        {
            /// <summary>
            /// * 
            /// </summary>
            public readonly static Field All = new Field("*", "TB_Sys_SpecialityLevelMapping");
            /// <summary>
            /// 主键
            /// </summary>
            public readonly static Field SpecialityLevelID = new Field("SpecialityLevelID", "TB_Sys_SpecialityLevelMapping", "主键");
            /// <summary>
            /// 专业编码
            /// </summary>
            public readonly static Field SpecialityKindsNO = new Field("SpecialityKindsNO", "TB_Sys_SpecialityLevelMapping", "专业编码");
            /// <summary>
            /// 考试级别
            /// </summary>
            public readonly static Field ExamLevelNO = new Field("ExamLevelNO", "TB_Sys_SpecialityLevelMapping", "考试级别");
            /// <summary>
            /// 考试级别名称
            /// </summary>
            public readonly static Field ExamLevelName = new Field("ExamLevelName", "TB_Sys_SpecialityLevelMapping", "考试级别名称");
        }
        #endregion


    }
}

